package cn.net.msg.utils;

import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Properties;

/**
 * <p>
 * FileName: FilePathUtils.java
 * </p>
 * <p>
 * Description: 读取properties文件工具类
 * <p>
 * Copyright: surepassserver(c) 2012
 * </p>
 * <p>
 * @author Vic Su
 * </p>
 * <p>
 * @content andyliu900@gmail.com
 * </p>
 * <p>
 * @version 1.0
 * </p>
 * <p>
 * CreatDate: 2012-11-10 下午09:44:54
 * </p>
 * <p>
 * Modification History
 */
public class FilePathUtils {

    private static Properties properties = new Properties();
    static{
        try {
            InputStreamReader is = new InputStreamReader(FilePathUtils.class.getClassLoader().getResourceAsStream("system-params.properties"),"UTF-8");
            properties.load(is);
        } catch (IOException e) {
            e.printStackTrace();
        }
    }

    public static String readValue(String key){     
        return (String)properties.get(key);
    }
}
